#!/bin/bash
DRIVE=$1
if ! [[ -d $DRIVE ]]; then echo "Bad drive $DRIVE"; exit; fi;
FILE=genyris-src-`date +%Y%m%d%H%M`.jar
echo creating $FILE
cd ~/workspace
jar cf ~/archives/$FILE Genyris
echo copying to $DRIVE
cp -p ~/archives/$FILE $DRIVE
sync
echo archive $FILE has `jar tf $DRIVE/$FILE| wc -l` files
